<?php
// +----------------------------------------------------------------------
// | ThinkCMF [ WE CAN DO IT MORE SIMPLE ]
// +----------------------------------------------------------------------
// | Copyright (c) 2013-2017 http://www.thinkcmf.com All rights reserved.
// +----------------------------------------------------------------------
// | Author: Dean <zxxjjforever@163.com>
// +----------------------------------------------------------------------
namespace api\wxapp\controller;

use cmf\controller\RestBaseController;
use wxapp\aes\WXBizDataCrypt;

class UserController extends RestBaseController
{
    // 获取用户信息
    public function getUserInfo()
    {



    }

    public function score_store () {
      $user = $this->user;
      $score = $user['score'];
      $reward_score = 100;
      $awards = [
        ['name' => '200元购物卡', 'picture' => 'http://www.feiyueka.com/admins/down/201111031126421311.jpg', 'price' => 2000],
        ['name' => '200元购物卡', 'picture' => 'http://www.feiyueka.com/admins/down/201111031126421311.jpg', 'price' => 2000],
        ['name' => '200元购物卡', 'picture' => 'http://www.feiyueka.com/admins/down/201111031126421311.jpg', 'price' => 2000],
        ['name' => '200元购物卡', 'picture' => 'http://www.feiyueka.com/admins/down/201111031126421311.jpg', 'price' => 2000],
        ['name' => '200元购物卡', 'picture' => 'http://www.feiyueka.com/admins/down/201111031126421311.jpg', 'price' => 2000],
        ['name' => '200元购物卡', 'picture' => 'http://www.feiyueka.com/admins/down/201111031126421311.jpg', 'price' => 2000],
        ['name' => '200元购物卡', 'picture' => 'http://www.feiyueka.com/admins/down/201111031126421311.jpg', 'price' => 2000],
        ['name' => '200元购物卡', 'picture' => 'http://www.feiyueka.com/admins/down/201111031126421311.jpg', 'price' => 2000],
        ['name' => '200元购物卡', 'picture' => 'http://www.feiyueka.com/admins/down/201111031126421311.jpg', 'price' => 2000],
      ];

      return [
        'score' => $score,
        'reward_score' => $reward_score,
        'introduce' => '邀请新用户、成交、带看、推荐房源等操作均可获得积分，功能陆续上线中',
        'awards' => $awards,
        'custom_tel' => '400-688-6666',
      ];
    }

}
